package com.ruoyi.ucar.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.domain.UCarBaseEntity;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;

/**
 * 客户主对象 t_customer
 * 
 * @author sungangbin
 * @date 2025-05-13
 */
@TableName("t_customer")
@Data
public class TCustomer extends UCarBaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键 */
    @TableId(value="id",type = IdType.AUTO)
    private Long id;

    /** 客户主表主键UUID */
    @Excel(name = "客户主表主键UUID")
    @TableField("customer_uuid")
    private String customerUuid;

    /** 客户姓名 */
    @Excel(name = "客户姓名")
    @TableField("customer_name")
    private String customerName;

    /** 客户电话 */
    @Excel(name = "客户电话")
    @TableField("customer_phone")
    private String customerPhone;

    /** 客户微信号 */
    @Excel(name = "客户微信号")
    @TableField("customer_wechat")
    private String customerWechat;

    /** 注册时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "注册时间", width = 30, dateFormat = "yyyy-MM-dd")
    @TableField("register_datetime")
    private Date registerDatetime;

    /** 客户类型-字典 */
    @Excel(name = "客户类型-字典")
    @TableField("customer_type")
    private String customerType;

    /** 上级代理uuid */
    @Excel(name = "上级代理uuid")
    @TableField("parent_customer_uuid")
    private String parentCustomerUuid;

    /** 充值余额 */
    @Excel(name = "充值余额")
    @TableField("balance_number")
    private BigDecimal balanceNumber;

    /** 赠送金额 */
    @Excel(name = "赠送金额")
    @TableField("gift_money")
    private BigDecimal giftMoney;

    /** 赠送金额 */
    @Excel(name = "返现金额")
    @TableField("return_money")
    private BigDecimal returnMoney;

    /** 赠送金额 */
    @Excel(name = "总计代理费")
    @TableField("total_agency_fee")
    private BigDecimal totalAgencyFee;

    /** 奖励开闭标志：1打开0关闭 */
    @Excel(name = "奖励开闭标志：1打开0关闭")
    @TableField("reward_flag")
    private Long rewardFlag;

    /** 分享编号 */
    @Excel(name = "分享编号")
    @TableField("share_code")
    private String shareCode;
    /**
     * 备注
     */
    @Excel(name = "备注")
    @TableField("remark")
    private String  remark;

    @Excel(name = "真实姓名")
    @TableField("real_name")
    private String  realName;

    @Excel(name = "身份证号码")
    @TableField("card_no")
    private String  cardNo;

    @Excel(name = "签名图片文件主表Uuid")
    @TableField("sign_file_main_uuid")
    private String  signFileMainUuid;


    /** 创建人 */
    @Excel(name = "创建人")
    @TableField("created_by")
    private String createdBy;

    /** 创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
    @TableField("created_time")
    private Date createdTime;

    /** 更新人 */
    @Excel(name = "更新人")
    @TableField("updated_by")
    private String updatedBy;

    /** 更新时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
    @TableField("updated_time")
    private Date updatedTime;

    /** 删除标志 */
    @Excel(name = "删除标志")
    @TableField("delete_flag")
    private Long deleteFlag;


    /** 关联sys_user用户表主键user_id */
    @Excel(name = "关联sys_user用户表主键user_id")
    @TableField("sys_user_id")
    private Long sysUserId;


    @Excel(name = "报告未读数量")
    @TableField("report_unread_number")
    private Integer reportUnreadNumber;

    @Excel(name = "头像地址")
    @TableField("avatar_url")
    private String avatarUrl;

    /** 代理商等级 */
    @Excel(name = "代理商等级")
    @TableField("agent_grade")
    private String agentGrade;

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("customerUuid", getCustomerUuid())
                .append("customerName", getCustomerName())
                .append("customerPhone", getCustomerPhone())
                .append("customerWechat", getCustomerWechat())
                .append("registerDatetime", getRegisterDatetime())
                .append("customerType", getCustomerType())
                .append("parentCustomerUuid", getParentCustomerUuid())
                .append("balanceNumber", getBalanceNumber())
                .append("giftMoney", getGiftMoney())
                .append("returnMoney", getReturnMoney())
                .append("totalAgencyFee", getTotalAgencyFee())
                .append("rewardFlag", getRewardFlag())
                .append("shareCode", getShareCode())
                .append("remark", getRemark())
                .append("signFileMainUuid", getSignFileMainUuid())
                .append("createdBy", getCreatedBy())
                .append("createdTime", getCreatedTime())
                .append("updatedBy", getUpdatedBy())
                .append("updatedTime", getUpdatedTime())
                .append("deleteFlag", getDeleteFlag())
                .append("sysUserId", getSysUserId())
                .append("reportUnreadNumber", getReportUnreadNumber())
                .append("avatarUrl", getAvatarUrl())
                .append("realName", getRealName())
                .append("cardNo", getCardNo())
                .append("agentGrade", getAgentGrade())
                .toString();
    }


}
